The Recursive Union of Some Gradual Types
نویسندگان
چکیده
We study union types and recursive types in the setting of a gradually typed lambda calculus. Our goal is to obtain a foundational account for languages that enable recursively defined data structures to be passed between static and dynamically typed regions of a program. We discuss how traditional sum types are not appropriate for this purpose and instead study a form of “true” union in the tradition of soft typing [Cartwright and Fagan, 1991] and occurrence typing [Tobin-Hochstadt and Felleisen, 2008]. Regarding recursive types, our formulation is based on the axiomatization of subtyping by Brand and Henglein (1998). This paper defines three artifacts. First, in the context of the simply typed lambda calculus, we define the semantics of our unions and integrate them with equi-recursive types. Second, we add a dynamic type ? to obtain a gradually typed lambda calculus. Its semantics is defined by translation to the third artifact, a blame calculus [Wadler and Findler, 2009] extended with unions and equi-recursive types.
منابع مشابه
A Gradual Interpretation of Union Types
Union types allow to capture the possibility of a term to be of several possibly unrelated types. Traditional static approaches to union types are untagged and tagged unions, which present dual advantages in their use. Inspired by recent work on using abstract interpretation to understand gradual typing, we present a novel design for union types, called gradual union types. Gradual union types ...
متن کاملتغییر رویکرد گروههای اسلامی ترکیه در روند الحاق به اتحادیه اروپا
This paper aims to investigate the change in the approach of Turkey’s Islamic political, social and economic groups in process of accession to the European :::::::union:::::::. It seems that process of Turkey’s accession to the European :::::::union::::::: that has led to more Europeanization of this country, is one of the most important factors in the gradual change of preferences, behavior an...
متن کاملThe eccentric connectivity index of bucket recursive trees
If $G$ is a connected graph with vertex set $V$, then the eccentric connectivity index of $G$, $xi^c(G)$, is defined as $sum_{vin V(G)}deg(v)ecc(v)$ where $deg(v)$ is the degree of a vertex $v$ and $ecc(v)$ is its eccentricity. In this paper we show some convergence in probability and an asymptotic normality based on this index in random bucket recursive trees.
متن کاملRefutable Inductive Inference of Recursive Functions
Learning of recursive functions refutably informally means that for every recursive function, the learning machine has either to learn this function or to refute it, that is to signal that it is not able to learn it. Three modi of making precise the notion of refuting are considered. We show that the corresponding types of learning refutably are of strictly increasing power, where already the m...
متن کاملOn the Stability by Union of Reducibility Candidates
We investigate some aspects of proof methods for the termination of (extensions of) the second-order λ-calculus in presence of union and existential types. We prove that Girard’s reducibility candidates are stable by union iff they are exactly the non-empty sets of terminating terms which are downward-closed w.r.t. a weak observational preorder. We show that this is the case for the Curry-style...
متن کامل